#pragma once
#include "pgl/core/pgl.h"
#include "pgl/core/PGLInclude.h"
#include "pgl/mfc/PGLMFCInclude.h"
#include "pgl/core/PGLLine2D.h"

class CPGLGeoPoint:public CPGLLine2D
{
private:
	bool m_canMove;
	bool m_canLeftAndRightMove;
	bool m_canTopAndBottomMove;
	double m_minX;
	double m_minY;
	double m_maxX;
	double m_maxY;
	bool m_bIsNuggest;
	int m_nVarioNo;
	bool m_OnlyOffset;
public:
	CPGLGeoPoint():m_canMove(true),m_canTopAndBottomMove(true),m_canLeftAndRightMove(true),m_minX(DOUBLE_MIN_VAULE),m_minY(DOUBLE_MIN_VAULE),m_maxX(DOUBLE_MAX_VAULE),m_maxY(DOUBLE_MAX_VAULE),m_OnlyOffset(false)
	{
		m_bIsNuggest=false;
		m_nVarioNo=0;
	}
	void SetCanMove(bool canMove){m_canMove=canMove;}
	bool GetCanMove(){return m_canMove;}
	void SetCanLeftAndRightMove(bool canLeftAndRightMove)
	{
		if(m_canMove)
			m_canLeftAndRightMove=canLeftAndRightMove;
	}
	bool GetCanLeftAndRightMove(){return m_canLeftAndRightMove;}

	void SetCanTopAndBottomMove(bool canTopAndBottomMove)
	{
		if(m_canMove)
			m_canTopAndBottomMove=canTopAndBottomMove;
	}
	bool GetCanTopAndBottomMove(){return m_canTopAndBottomMove;}

	void SetMinX(double minX){m_minX=minX;}
	double GetMinX(){return m_minX;}
	void SetMinY(double minY){m_minY=minY;}
	double GetMinY(){return m_minY;}

	void SetMaxX(double maxX){m_maxX=maxX;}
	double GetMaxX(){return m_maxX;}
	void SetMaxY(double maxY){m_maxY=maxY;}
	double GetMaxY(){return m_maxY;}

	void SetIsNuggest(bool bIsNuggest) {m_bIsNuggest=bIsNuggest;}
	bool GetIsNuggest() {return m_bIsNuggest;}
	void SetVarioNo(int nVarioNo) {m_nVarioNo=nVarioNo;}
	int GetVarioNo() {return m_nVarioNo;}
	bool IsOnlyOffset(){return m_OnlyOffset;}
	void SetOnlyOffset(bool onlyOffset){m_OnlyOffset=onlyOffset;}
};

PGL_DECLARE_SMARTPTR(CPGLGeoPoint);